<template>
	<view class="classLayout pageBg">
		<custom-nav-bar title="分类"></custom-nav-bar>
		<view class="classify">
			<theme-item v-for="i in classfiyList" :key="i._id"
			:item="i"></theme-item>
		</view>
	</view>
</template>

<script setup>
import { ref } from 'vue';
import {apiGetClassify} from '@/Api/api.js'
import { onShareAppMessage, onShareTimeline } from "@dcloudio/uni-app"
const classfiyList = ref([])


const getClassify = async()=>{
	let res = await apiGetClassify({pageSize:15});
	// console.log(res);
	classfiyList.value = res.data
}
getClassify()

//分享模块
onShareAppMessage((e)=>{
	return {
		title:"壁纸推荐————su",
		path:"/pages/index/index",
		// imageUrl:'/static/xxmLogo.png'
	}
})

//分享朋友圈
onShareTimeline((e) =>{
	return {
		title:"壁纸推荐~~~~su",
		path:"/pages/index/index",
		imageUrl:'/static/xxmLogo.png'
	}
})
	
</script>

<style lang="scss" scoped>
	.classify{
		padding: 30rpx;
		display: grid;
		grid-template-columns: repeat(3, 1fr);
		gap: 15rpx;
	}
</style>
